package br.com.SRP.Controle;

import java.util.List;

import br.com.SRP.Dao.Ckl01ParametroCheckListDAO;
import br.com.SRP.Modelo.Ckl01ParametroCheckList;
import br.com.SRP.Modelo.Eqp08Combustivel;


public class ControlParametroCkl {
	private Ckl01ParametroCheckList cklParamCkl;

	private Ckl01ParametroCheckListDAO cklParamCklDAO; 
 
	private int codigo; 

	public ControlParametroCkl() {
		cklParamCkl = new  Ckl01ParametroCheckList();
		cklParamCklDAO = new Ckl01ParametroCheckListDAO();

	}

	public void save(Ckl01ParametroCheckList cklParamCkl) throws Exception {
		cklParamCklDAO.salvar(cklParamCkl);
	}
	
	public void remove(int codigo) {
		System.out.println(codigo);
		this.cklParamCkl.setCodigo(codigo);
		cklParamCklDAO.excluir(this.cklParamCkl.getCodigo());
		this.cklParamCkl = new Ckl01ParametroCheckList();
	}
	
	public List<Ckl01ParametroCheckList> getParametroCkl(Integer codigoEqp, Integer tipoCkl) {
		return cklParamCklDAO.listar(codigoEqp, tipoCkl);
	} 
	
}
